﻿<%@ Page Title="" Language="C#" StylesheetTheme="AdminTheme" MasterPageFile="~/Backend/mtpAdmin.master"
    AutoEventWireup="true" CodeBehind="DetaiChitiet.aspx.cs" Inherits="HPortal.Backend.DetaiChitiet" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="dvTitleContent">
        Quản lý Đề tài</div>
    <fieldset>
        <legend>Thông tin chi tiết của đề tài</legend>
        <table class="ArticleDetailTable">
            <tr>
                <td class="ArticleDetailTitle" colspan="2">
                    Thông tin chi tiết đề tài
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2">
                    Mã số:
                    <asp:TextBox ID="txtMaso" runat="server"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2">
                    Tên đề tài:<br />
                    <asp:TextBox ID="txtTenDetai" runat="server" Rows="3" TextMode="MultiLine" Width="100%"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2">
                    <b>Mục tiêu:
                        <br />
                        <asp:TextBox ID="txtMuctieu" runat="server" Rows="5" TextMode="MultiLine" Width="100%"></asp:TextBox>
                    </b>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2">
                    <b>Kết quả đạt được:</b>
                    <br />
                    <b>
                        <asp:TextBox ID="txtKetqua" runat="server" Rows="5" TextMode="MultiLine" Width="100%"></asp:TextBox>
                    </b>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead">
                    <b>Đơn vị thực hiện:&nbsp; </b>&nbsp;<asp:DropDownList ID="cboDonvi" runat="server"
                        Width="200px" AutoPostBack="True" OnSelectedIndexChanged="cboDonvi_SelectedIndexChanged">
                    </asp:DropDownList>
                </td>
                <td class="ArticleDetailHead">
                    <b>Chủ nhiệm đề tài:&nbsp; </b>&nbsp;<asp:DropDownList ID="cboChunhiem" runat="server"
                        Width="200px">
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead">
                    <b>Cấp thực hiện:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </b>&nbsp;<asp:DropDownList ID="cboCap"
                        runat="server" Width="200px">
                    </asp:DropDownList>
                </td>
                <td class="ArticleDetailHead">
                    <b>Loại đề tài:</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <asp:DropDownList ID="cboLoai" runat="server" Width="200px">
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead">
                    <b>Trạng thái:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    </b>&nbsp;<asp:DropDownList ID="cboTrangthai" runat="server" Width="200px">
                        <asp:ListItem Value="0">Chưa triển khai</asp:ListItem>
                        <asp:ListItem Value="1">Đang thực hiện</asp:ListItem>
                        <asp:ListItem Value="2">Đã hoàn thành</asp:ListItem>
                    </asp:DropDownList>
                </td>
                <td class="ArticleDetailHead">
                    <b>Lĩnh vực:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    </b>&nbsp;<asp:DropDownList ID="cboLinhvuc" runat="server" Width="200px">
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2" runat="server" id="rTiendo">
                    <b>Thời gian, kinh phí thực hiện:</b>
                    <asp:GridView ID="grvTiendo" runat="server" AutoGenerateColumns="False" SkinID="tGridview"
                        Width="40%" OnSelectedIndexChanged="grvTiendo_SelectedIndexChanged">
                        <Columns>
                            <asp:BoundField DataField="Nam" HeaderText="Năm" ItemStyle-HorizontalAlign="Left">
                                <ItemStyle HorizontalAlign="Justify"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="Kinhphi" HeaderText="Kinh phí (triệu)">
                                <ItemStyle Width="150px" />
                            </asp:BoundField>
                            <asp:TemplateField ShowHeader="False">
                                <ItemTemplate>
                                    <asp:LinkButton ID="lnkChonTiendo" runat="server" CausesValidation="False" CommandName="Select"
                                        Text="Chọn" CommandArgument='<%# DataBinder.Eval(Container, "DataItem.TiendoID")%>'
                                        OnClick="lnkChonTiendo_Click"></asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField ShowHeader="False">
                                <ItemTemplate>
                                    <asp:LinkButton ID="lnkXoaTiendo" runat="server" CausesValidation="False" CommandName="Select"
                                        Text="Xóa" CommandArgument='<%# DataBinder.Eval(Container, "DataItem.TiendoID")%>'
                                        OnClick="lnkXoaTiendo_Click"></asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <br />
                    Năm:
                    <asp:TextBox ID="txtNam" runat="server"></asp:TextBox>
                    <asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txtNam"
                        ErrorMessage="*" MaximumValue="2050" MinimumValue="2000" Type="Integer"></asp:RangeValidator>
                    &nbsp;&nbsp; Kinh phí (triệu):
                    <asp:TextBox ID="txtKinhphi" runat="server"></asp:TextBox>
                    <asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="txtKinhphi"
                        ErrorMessage="*" MaximumValue="50000" MinimumValue="10" Type="Double"></asp:RangeValidator>
                    &nbsp;&nbsp;&nbsp;
                    <asp:Button ID="cmdThemTiendo" runat="server" Text="Thêm tiến độ thực hiện" OnClick="cmdThemTiendo_Click" />
                    &nbsp;
                    <asp:Button ID="cmdEditTiendo" runat="server" OnClick="cmdEditTiendo_Click" Text="Sửa" />
                </td>
            </tr>
            <tr>
                <td colspan="2">
                    &nbsp;
                    <br />
                    <asp:Button ID="cmdUpdate" runat="server" Text="Cập nhật thông tin" OnClick="cmdUpdate_Click" />
                    &nbsp;&nbsp;
                    <asp:Button ID="cmdDelete" runat="server" Text="Xóa thông tin đề tài" OnClick="cmdDelete_Click" />
                </td>
            </tr>
            <tr>
                <td class="ArticleDetailHead" colspan="2" runat="server" id="rBaocao">
                    Danh sách báo cáo của đề tài<br />
                    <asp:GridView ID="grvArticlelList" runat="server" AutoGenerateColumns="False" SkinID="tGridview"
                        Width="100%" OnSelectedIndexChanged="grvArticlelList_SelectedIndexChanged">
                        <Columns>
                            <asp:BoundField DataField="Title" HeaderText="Tên báo cáo" ItemStyle-HorizontalAlign="Left">
                                <ItemStyle HorizontalAlign="Justify"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="FileType" HeaderText="Loại tài liệu">
                                <ItemStyle Width="100px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="DocumentSize" HeaderText="Kích thước(KB)">
                                <ItemStyle Width="110px" />
                            </asp:BoundField>
                            <asp:TemplateField HeaderText="Tải về">
                                <ItemTemplate>
                                    <a href='<%# System.Configuration.ConfigurationManager.AppSettings["OsPortal.PortalCore.WebPathUserFilesUpload"].ToString() + "/" + DataBinder.Eval(Container, "DataItem.UploadFileID") + "." + DataBinder.Eval(Container, "DataItem.FileExt").ToString().Trim()%>'>
                                        Download </a>
                                </ItemTemplate>
                                <ItemStyle Width="100px" />
                            </asp:TemplateField>
                            <asp:TemplateField ShowHeader="False">
                                <ItemTemplate>
                                    <asp:LinkButton ID="lnkChonBaocao" runat="server" CausesValidation="False" CommandName="Select"
                                        Text="Xóa" 
                                        CommandArgument='<%# DataBinder.Eval(Container, "DataItem.BaocaoID") %>' 
                                        onclick="lnkChonBaocao_Click"></asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                                        Tên báo cáo:
                    <asp:textbox id="txtTitle" runat="server" Width="400px"></asp:textbox><br />
                    			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    			<INPUT id="flUpload" type="file" name="File1" runat="server">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;
            <asp:button id="cmdInsert" runat="server" Text="Thêm báo cáo" 
                onclick="cmdInsert_Click" Width="119px"></asp:button>
                </td>
            </tr>
        </table>
    </fieldset>
</asp:Content>
<asp:Content ID="Content2" runat="server" contentplaceholderid="head">
    <style type="text/css">
        #flUpload
        {
            width: 394px;
        }
    </style>
</asp:Content>

